<template>
  <div class="about">
    <h1>This is an about page</h1>
    <button @click="del">删除</button>
  </div>
</template>
<script>
import request from '../util/request'
export default {
    created(){
        // {csrfToken:'nYHHbEINFRFW7G6RjawmTHF',a:1}
        request.post('/api/add',{username:'lixd',password:'123'}).then(res => {
            console.log(res)
        })
    },
    methods:{
        del(){
            request.get('/api/del',{id:1}).then(res => {
                console.log(res)
            })
        }
    }
}
</script>
